home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The Arsenal Files 6
/
The Arsenal Files 6 (Arsenal Computer).ISO
/
os2bbs
/
ftpfid16.zip
/
FTPRPT.CMD
< prev
next >
Wrap
OS/2 REXX Batch file
|
1995-12-17
|
862b
|
33 lines
/* FTPRPT.CMD */
ftplog = 'f:\bbs\logs\ftpfido.log'
IF Stream(ftplog,'C', 'Query Exists') <>' ' Then
Do
rc = stream(ftplog,'C','open read')
total_sent = 0
total_rec = 0
total_time = 0
total_sec = 0
do until LINES(ftplog) = 0
line = LINEIN(ftplog)
If Pos(' $', line) = 1 then
Do
parse var line sent sentmuch bytes dytes recmuch rest ters muchtime mo muchsec eee
total_sent = total_sent + sentmuch
total_rec = total_rec + recmuch
total_time = total_time + muchtime
total_sec = total_sec + muchsec
if total_sec > 59 then do
total_time = total_time + 1
total_sec = total_sec - 60
end
end
end /* Do Until */
rc = stream(ftplog,'C','close')
say 'Todays Stats: 'total_sent 'sent - 'total_rec 'recieved'
say total_time%60 'hours or 'total_time 'minutes 'total_sec 'secs'
'pause'
end